#include "vector.h"

	 MemoryPool<Vector, vectorChunkSize> Vector::vectorPool;
	 int Vector::liveObjectCount = 0;	

	Vector::Vector():
	x(0.0), y(0.0), z(0.0) 
	{
		liveObjectCount++;
	}

	Vector::~Vector()
	{
		liveObjectCount--;
	}

	
	
	void* Vector::operator new(size_t)
	{
		return vectorPool.allocate();
	}

	void Vector::operator delete(void* pointer)
	{
		vectorPool.free(static_cast<Vector*>(pointer));
	}
